package com.springboot.base.service;


import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.springboot.base.common.BusinessException;
import com.springboot.base.model.Seller;
import com.springboot.base.model.Shop;

import java.io.IOException;
import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author meiguangya
 * @since 2020-07-17
 */
public interface IShopService{

    Shop create(Shop shop) throws BusinessException;

    Shop get(Integer id);

    IPage<Shop> qryListByPage(Page<Shop> page);

    int countAllShop();

    List<Shop> recommend(BigDecimal longitude, BigDecimal latitude);

    List<Shop> search(BigDecimal longitude, BigDecimal latitude, String keyword, Integer orderby, Integer categoryId, String tags);

    Map<String,Object> searchByEsHighLeverl(BigDecimal longitude, BigDecimal latitude, String keyword, Integer orderby, Integer categoryId, String tags) throws IOException;

    Map<String,Object> searchByEsLowerLeverl(BigDecimal longitude,BigDecimal latitude,String keyword,Integer orderby,Integer categoryId,String tags) throws IOException;

    List<Map<String,Object>> searchGroupByTags(String keyword, Integer categoryId, String tags);
}
